<?php 
	class ConnectionDB{
		
		protected $oLink, $sQuery = "";
		private $sServer, $sUsername, $sPassword, $sDb;
		
		public function ConnectionDB(){
			$this->sServer = "localhost";
			$this->sUsername = "root";
			$this->sPassword = "";
			$this->sDb = "calendario_CCU";
			$this->connect();
		}
		
		public function _construct(){
			$this->sServer = "localhost";
			$this->sUsername = "root";
			$this->sPassword = "cys150308";
			$this->sDb = "calendario_CCU";
			$this->connect();
		}
		
		protected function connect(){
			$this->oLink = mysql_connect($this->sServer, $this->sUsername, $this->sPassword) or die("Error en la conexión con el Servidor");
			@mysql_select_db($this->sDb, $this->oLink) or die("Error en la conexion con la base de datos");
		}
		
		protected function desconnect(){
				
		}
		
		protected function begin() {
			mysql_query("BEGIN", $this->oLink);
		}

		protected function rollback() {
			mysql_query("ROLLBACK", $this->oLink);
		}

		protected function commit() {
			mysql_query("COMMIT", $this->oLink);
		}	
	}
?>